import request from '@/utils/request'

// 查询用户充电记录列表
export function listChargeRecord(query) {
  return request({
    url: '/weiriya/chargeRecord/list',
    method: 'get',
    params: query
  })
}

// 查询用户充电记录详细
export function getChargeRecord(id) {
  return request({
    url: '/weiriya/chargeRecord/' + id,
    method: 'get'
  })
}

// 新增用户充电记录
export function addChargeRecord(data) {
  return request({
    url: '/weiriya/chargeRecord',
    method: 'post',
    data: data
  })
}

// 修改用户充电记录
export function updateChargeRecord(data) {
  return request({
    url: '/weiriya/chargeRecord',
    method: 'put',
    data: data
  })
}

// 删除用户充电记录
export function delChargeRecord(id) {
  return request({
    url: '/weiriya/chargeRecord/' + id,
    method: 'delete'
  })
}
